<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
    
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>My Home</title>

<style>
#main{

	width:1200px;
	margin:auto;/*마진이 오토이기 때문에 자동적으로 중앙에 배치되게 된다.*/

}
#top,#bottom{
	width:100%;
	height:220px;
	position:relative;

}

#top{
	background:#FFFFFF;
}

#left{
	background-color: #B7F0B1;
	vertical-align: top;
	width:250px;
	height:800px;
	margin-top:10px;
	display:inline-block;

}
#content{
	vertical-align: top;
	width:750px;
	margin:0px;
	display:inline-block;
	vertical-align: top;

}
#right{
	vertical-align: top;
	width:100px;
	margin:0px;
	display:inline-block;

}


</style>

<script>
var param=new Object(); 


</script>

</head>
<body>


<%//자바 영역
request.setCharacterEncoding("utf-8");

String inc_left="none.jsp";
String inc_right="none.jsp";
String inc_content="none.jsp";
String temp=null;


//------------------------------------------------------------------------------
//왼쪽 메뉴(left)
//------------------------------------------------------------------------
temp = request.getParameter("inc_left");
if(temp == null || temp == ""){
	
	inc_left=(String)session.getAttribute("inc_left");
	
}else{
	session.setAttribute("inc_left", temp);
	inc_left=temp;
	
}
	if(inc_left==null) inc_left="none.jsp";
	

//-----------------------------------------------
//오른쪽 광고(aside)
//-------------------------------------------------
temp = request.getParameter("inc_right");//top에서 연결시킨 변수를 가져옴
if(temp == null || temp == ""){ 
	inc_right=(String)session.getAttribute("inc_right");
	
}else{
	session.setAttribute("inc_right", temp);
	inc_right=temp;
}
if(inc_right==null)inc_right="none.jsp";


//------------------------------------------------------
//컨텐츠 내용(content)
//------------------------------------------------------
temp=request.getParameter("inc_content");
if(temp == null || temp == ""){ 
	inc_content=(String)session.getAttribute("inc_content");
	
 }else{
 session.setAttribute("inc_content", temp);
 inc_content=temp;
 }

if(inc_content==null)inc_content="none.jsp";


%>

<div id='main'>
	<div id='top'>
		 <%@include file='top.jsp' %> 
	</div>
	<div id='center'>
	   
		<div id='left'>
			<jsp:include page="<%= inc_left%>"/></div>
			
		<div id='content'>
			<jsp:include page="<%= inc_content%>"/></div>	
		
		<!--변수실행 -->
		<div id='right'>
			<jsp:include page="<%= inc_right%>"/></div>
			
	</div>
	
	<div id='bottom'>
		<%@include file='bottom.jsp' %>
	</div>
	
</div>
</body>

</html>